import React, { Component } from 'react';
import CSS from './InputItem.less';

class InputItem extends Component {

  render() {
    return (
        <div className={CSS.row}>
            {this.props.leftIcon }
            <input
                type={this.props.isPassword ? "password": "text"}
                placeholder={this.props.placeholder}
                onChange={e => this.props.onchange(e)}
                value={this.props.inputValue}
            />
            {this.props.rightIcon }
            {this.props.children}
        </div>
    )
  }
}

export default InputItem